package pl.planito.entity;

import java.io.Serializable;
import javax.persistence.*;


/**
 * The persistent class for the inv_software database table.
 * 
 */
@Entity
@Table(name="inv_software")
public class InvSoftware implements Serializable {
	private static final long serialVersionUID = 1L;

	@EmbeddedId
	private InvSoftwarePK id;

	@Column(name="license_type")
	private String licenseType;

	private int version;

	//bi-directional many-to-one association to Inventory
	@ManyToOne(fetch=FetchType.LAZY)
	@JoinColumns({
		@JoinColumn(name="inventory_id_soft", referencedColumnName="id", insertable=false, updatable=false),
		@JoinColumn(name="inventory_inv_id_soft", referencedColumnName="inv_id", insertable=false, updatable=false)
		})
	private Inventory inventory;

    public InvSoftware() {
    }

	public InvSoftwarePK getId() {
		return this.id;
	}

	public void setId(InvSoftwarePK id) {
		this.id = id;
	}
	
	public String getLicenseType() {
		return this.licenseType;
	}

	public void setLicenseType(String licenseType) {
		this.licenseType = licenseType;
	}

	public int getVersion() {
		return this.version;
	}

	public void setVersion(int version) {
		this.version = version;
	}

	public Inventory getInventory() {
		return this.inventory;
	}

	public void setInventory(Inventory inventory) {
		this.inventory = inventory;
	}
	
}